package com.mininglamp.app.util;

import java.io.File;

import com.google.common.base.Strings;

/**
 * 文件工具类
 * 
 * @author kevin
 *
 */
public class Files {

	/**
	 * 拼接文件路径
	 * 
	 * @param args
	 * @return
	 */
	public static String join(String... args) {
		String path = "";
		for (String arg : args) {
			if (Strings.isNullOrEmpty(arg)) {
				continue;
			}
			if (Strings.isNullOrEmpty(path)) {
				path = arg;
			} else {
				path = new File(path, arg).getPath();
			}
		}
		return path;
	}

}
